<!doctype html>
<html lang="en">
<head>
    <link href="//cdn.bootcss.com/bootstrap/3.3.0/css/bootstrap.min.css" rel="stylesheet">
    <meta charset="UTF-8">
    <title>查看用户列表</title>
    <style>
        body{
            color: #333;
            font: 16px Verdana, "Helvetica Neue", helvetica, Arial, 'Microsoft YaHei', sans-serif;
            margin: 0px;
            padding: 20px;
        }

        a{
            color: #868686;
            cursor: pointer;
        }
        a:hover{
            text-decoration: underline;
        }
        h2{
            color: #4288ce;
            font-weight: 400;
            padding: 6px 0;
            margin: 6px 0 0;
            font-size: 28px;
            border-bottom: 1px solid #eee;
        }
        div{
            margin:8px;
        }
        div.content{
            margin-left: 200px;
        }
        div.content_list{
            float: left;
        }
        div.content_add{
            float: left;
        }
        .option_01{
            width: 167px;
        }
    </style>
</head>
<body>
<h1 align="center">后台管理</h1>

<div class="content">
    <div class="content_add">
        <h2>个人信息</h2>
        <form action="" method="post">
            <div>账户名称:{:$username}</div>
            <div><a href="{:url('admin/index/adminLogout')}">登出</a></div>

        </form>
        <br>
        <h2>添加商品</h2>
        <form action="{:url('admin/goods/add')}" method="post">
            <div>商品名称:<input type="text" name="title" id="title" placeholder="请输入商品名称" style="float: right"></div>
            <div>商品原价:<input type="text" name="old_price" id="old_price" placeholder="请输入商品原价" style="float: right"></div>
            <div>商品现价:<input type="text" name="new_price" id="new_price" placeholder="请输入商品现价" style="float: right"></div>
            <div style="margin-bottom: 27px;">商品简介:<textarea  name="description" id="description" placeholder="请输入商品简介" style="float: right;width: 208px;"></textarea></div>
            <div>商品链接:<input type="text" name="url" id="url" placeholder="请输入商品链接" value="http://" style="float: right"></div>
            <div>优惠券链接:<input type="text" name="ticket_url" id="ticket_url" placeholder="请输入优惠券链接" value="http://" style="float: right"></div>
            <div>商品图片链接:<input type="text" name="pictrue_url" id="pictrue_url" placeholder="请输入商品图片链接" value="http://" style="float: right"></div>
            <div style="float:right;"><input type="submit" value="提交" name="dosubmit" id="dosubmit" ></div>
        </form>
        <br><br>
        <!--<h2>编辑推荐</h2>
        <form action="" method="post">
            <div>
                选择商品:
                <select class="option_01">
                    {volist name="list" id="goods"}
                        <option id="{$goods.Id}"  name="title">{$goods.title}</option>
                    {/volist}
                </select>
            </div>
        </form>-->
    </div>

    <div class="content_list">
        <h2>已有商品列表（{$list->total()}）</h2>
        {volist name="list" id="goods"}
            ID：{$goods.Id}<br/>
            商品名称：{$goods.title}<br/>
            商品简介：{$goods.description}<br/>
            商品链接：<a href="{$goods.url}" target="_blank">点击这里</a><br/>
            减券链接：<a href="{$goods.ticket_url}" target="_blank">点击这里</a><br/>
            更新时间：{$goods.update_time}<br/>
            <a href="{:url('admin/Goods/edit'),'?id='.$goods.Id}">编辑</a>&nbsp;&nbsp;
            <a href="#">推荐</a>&nbsp;&nbsp;
            <a href="{:url('admin/Goods/del'),'?id='.$goods.Id}">删除</a>&nbsp;&nbsp;<br/>
            ------------------------<br/>
        {/volist}
        {$list->render()}
    </div>
</div>


</body>
</html>